<?php

namespace app\proxy\model\file;

use app\common\model\file\UploadGroup as UploadGroupModel;

class UploadGroup extends UploadGroupModel
{
    /**
     * 获取列表记录
     */
    public function getList($groupType = '', $shop_supplier_id = 0, $proxy_id = 0)
    {
        $model = $this;
        !empty($groupType) && $model = $model->where('group_type', '=', trim($groupType));
        return $model->where('shop_supplier_id', '=', $shop_supplier_id)
            ->where('is_delete', '=', 0)
            ->where('proxy_id', '=', $proxy_id)
            ->order(['sort' => 'asc', 'create_time' => 'desc'])
            ->select();
    }
}